public class Company {
    String name;
    String location;
    String tele;
    String range;
//    Member[]e=new Member[10];
    Member e[]={
            new Member("赵一","28岁","男","财务",7000),
            new Member("王二","21岁","男","人事助理",3000),
            new Member("张三","22岁","男","工程师",6000),
            new Member("李四","33岁","男","采购",6500),
            new Member("钱五","28岁","女","人事",7000),
            new Member("黄六","43岁","男","财务总监",12000),
            new Member("管七","35岁","男","总经理",13000),
            new Member("石八","28岁","男","财务",7000),
            new Member("凡九","48岁","男","董事长",0),
            new Member("陈十","68岁","男","老板",0)};
    public Company(String name,String location,String tele,String range){
        this.name=name;
        this.location=location;
        this.tele=tele;
        this.range=range;
    }
    public void empfindTopSalary(){
        int max=0;
//        int count=0;
        for(int i=0;i<e.length;i++){
            if(e[i].salary>max){
                max=e[i].salary;
//                count=i;
            }
        }
        System.out.println("最高薪水是："+max);
//        System.out.println("最高薪水项是：\n"+e[count]);
    }
    //    public void add(){                                    //加成员方法类
//        Scanner in=new Scanner(System.in);
//        for(int i=0;i<e.length;i++)
//        {
//            System.out.println("请输入成员姓名：");
//            e[i].name=in.next();
//            System.out.println("请输入成员年龄：");
//            e[i].age=in.next();
//            System.out.println("请输入成员性别：");
//            e[i].sex=in.next();
//            System.out.println("请输入成员职位：");
//            e[i].work=in.next();
//            System.out.println("请输入成员薪资：");
//            e[i].salary=in.nextInt();
//        }
//    }
}
